1. Technical Field
The present invention relates to memory storage systems and methods and more particularly to temperature based memory hierarchy caching.
2. Description of the Related Art
Solid state devices (SSDs) provide much faster random access to data compared to conventional hard disk drives (HDD). Therefore, the response time of a database engine could be improved dramatically by exploiting the useful characteristics of SSDs.
Conventional replacement algorithms used by memory buffer pools are not adequate for an SSD. SSDs have a random write penalty for small fragments which is not considered by well known replacement algorithms. Current replacement algorithms also do not consider long-term statistics about the access frequency and method (random/sequential) of individual pages or regions.
SSDs store data persistently using NAND flash memory. While SSDs are more expensive than hard disks when measured in dollars per gigabyte, they are significantly cheaper when measured in dollars per random input/output (I/O) per second. For workloads with significant random I/O, there is an opportunity to add SSDs to the configuration. The use of these SSDs should be targeted to the portion of the workload that can benefit the most from random I/O savings. Using SSDs to store an entire enterprise-scale database is not currently cost-effective.
Transaction processing is an application in which random I/O may play a relatively significant role. Small update transactions may touch records that are widely distributed across a physical storage medium. Placement of certain tables and/or indexes selectively on an SSD may be studied to take maximal advantage of the SSD's performance advantages. A workload is profiled to determine which tables and indexes generate the most physical random I/O, and tables are placed on the SSD in order of decreasing I/O per page.
There are a few drawbacks to such an approach. First, a user must explicitly run a profiling tool to gather statistics, and then perform potentially expensive physical reorganizations as data is moved to/from the SSD. Second, decisions are made at the granularity of an entire table or index. In some cases, only part of the data in a table (e.g., the most recent data) may be frequently accessed, and one might hope to put just fragments of the table on the SSD.